package com.blog.common.mapper.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.blog.common.domain.entity.Talk;
import com.blog.common.domain.vo.TalkVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 说说 Mapper 接口
 * </p>
 *
 * @author Valerie
 * @since 2023-02-18
 */
@Mapper
public interface TalkMapper extends BaseMapper<Talk> {

    /**
     * 获取说说列表
     *
     * @param page 分页模型
     * @return {@link List<TalkVo>}
     */
    Page<TalkVo> listTalks(Page page);


    /**
     * 根据id查看说说
     *
     * @param talkId 说说id
     * @return {@link TalkVo} 说说信息
     */
    TalkVo getTalkById(@Param("talkId") Integer talkId);
}
